| API Documentation |  |

- MAIN PAGE
- NAMESPACES
- CLASSES

Color.h
1 // Color.h
3 //
5
6 namespace nkWinUi
7 {
11 class DLL_WINUI_EXPORT Color final
12 {
13 public :
14
19 Color () noexcept ;
30 explicit Color (unsigned char r, unsigned char g, unsigned char b, unsigned char a = 255) noexcept ;
41 explicit Color (float r, float g, float b, float a = 1.f) noexcept ;
52 explicit Color (double r, double g, double b, double a = 1.0) noexcept ;
63 explicit Color (unsigned int r, unsigned int g, unsigned int b, unsigned int a = 255u) noexcept ;
74 explicit Color (unsigned long long r, unsigned long long g, unsigned long long b, unsigned long long a = 255ull) noexcept ;
85 explicit Color (int r, int g, int b, int a = 255) noexcept ;
96 explicit Color (long long r, long long g, long long b, long long a = 255ll) noexcept ;
100 ~Color () ;
101
102 // Getters
106 float getR () const ;
110 float getG () const ;
114 float getB () const ;
118 float getA () const ;
124 unsigned int getR255 () const ;
130 unsigned int getG255 () const ;
134 unsigned int getB255 () const ;
140 unsigned int getA255 () const ;
141
150 Color getAssociateColor (float factor = 1.5f) const ;
158 Color mix (const Color& other, float factor) const ;
169 Color getColorForDepth (unsigned int depth) const ;
170
177 Color operator* (float factor) const ;
178 } ;
179 }
nkWinUi::Color
Represents a color, with 4 channels.
Definition: Color.h:12
nkWinUi
Encompasses all API of component NilkinsWinUi.
Definition: Clipboard.h:7
nkWinUi::Color::Color
Color() noexcept